package com.shop.cereshop.app.dao.buyer;

import com.shop.cereshop.commons.domain.buyer.CereBuyerSearch;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface CereBuyerSearchDAO {
    int deleteByPrimaryKey(Long searchId);

    int insert(CereBuyerSearch record);

    int insertSelective(CereBuyerSearch record);

    CereBuyerSearch selectByPrimaryKey(Long searchId);

    int updateByPrimaryKeySelective(CereBuyerSearch record);

    int updateByPrimaryKey(CereBuyerSearch record);

    List<CereBuyerSearch> getHistory(@Param("buyerUserId") Long buyerUserId);

    void delete(@Param("searchId") Long searchId);

    CereBuyerSearch findBySearch(@Param("search") String search, @Param("buyerUserId") Long buyerUserId);

    void updateBuyerData(@Param("buyerUserId") Long buyerUserId, @Param("id") Long id);
}